[sqlite] how to cross-compile sqlite for PPC?
hi, i'm running fedora core 3 and i need some help cross-compiling sqlite-3.2.2 for the PPC platform. i have the cross-compiler toolchain ELDK-3.1.1 installed and, like i've done with other packages, i ran the following: $ ../sqlite-3.2.2/configure --host=ppc-linux-gnu \ CC=ppc_8xx-gcc the tail end of the output is: Version set to 3.2 Release set to 3.2.2 Version number set to 3002002 checking for ppc-linux-gnu-gcc... (cached) ppc_8xx-gcc checking whether we are using the GNU C compiler... (cached) yes checking whether ppc_8xx-gcc accepts -g... (cached) yes checking for ppc_8xx-gcc option to accept ANSI C... (cached) none needed configure: error: unable to find a compiler for building build tools um ... what appears to be the problem here? certainly, i have the entire gnu development suite installed, and i've used this incantation to cross-compile other packages, like expat. thoughts? rday
[sqlite] operational errors on insert with Python
I have a Python/wxPython application that inserts data in many places into various tables in a sqlite database. All the inserts work fine except for the latest one: autoStartcursor.execute('INSERT INTO baseappstart (SerialNumber, Time, FUSoftwareVersion, GUISoftwareVersion, NexpertVersion, OSISVersion, SDMSVersion, Login) VALUES ('+serialNum+', '+timetemp+', '+fusBuildVer+', '+guiVerTemp+', '+nexpertVersion+', '+osisverData+', '+sdmsver+', '+accessLvl+')') I have printed out a test string which returns this: test string is INSERT INTO baseappstart (SerialNumber, Time, FUSoftwareVersion, GUISoftwareVersion, NexpertVersion, OSISVersion, SDMSVersion, Login) VALUES (1, 1119528625, unknown, 2.5.6, 02.05, 2.5.4, 1.0.0.1, Operator) as far as I can tell the syntax is correct, when I manually insert it using Sqlite Analyzer it works fine too. The error returned is OperationalError: near ., syntax error. When I cut this down to just sending this: autoStartcursor.execute(INSERT INTO baseappstart (SerialNumber) VALUES (+test+)), with test == 'finally', I get the following error: OperationalError: no such column: finally I've reached the end of what I can figure out about this, anyone have any thoughts, or seen this before?? __ IMPORTANT NOTICE: The information in this email is confidential and proprietary to NexPress Solutions, Inc. and may be legally privileged. It is for the intended recipient(s) named above only. Any unauthorized review, printing, copying, use or distribution of this email by anyone else is prohibited and may be a criminal offense. If you have received this email in error, please notify the sender immediately by reply email and delete the original message.
Re: [sqlite] how to cross-compile sqlite for PPC?
On Thu, 23 Jun 2005, Robert P. J. Day wrote: hi, i'm running fedora core 3 and i need some help cross-compiling sqlite-3.2.2 for the PPC platform. i have the cross-compiler toolchain ELDK-3.1.1 installed and, like i've done with other packages, i ran the following: $ ../sqlite-3.2.2/configure --host=ppc-linux-gnu \ CC=ppc_8xx-gcc the tail end of the output is: Version set to 3.2 Release set to 3.2.2 Version number set to 3002002 checking for ppc-linux-gnu-gcc... (cached) ppc_8xx-gcc checking whether we are using the GNU C compiler... (cached) yes checking whether ppc_8xx-gcc accepts -g... (cached) yes checking for ppc_8xx-gcc option to accept ANSI C... (cached) none needed configure: error: unable to find a compiler for building build tools um ... what appears to be the problem here? certainly, i have the entire gnu development suite installed, and i've used this incantation to cross-compile other packages, like expat. SQLite requires a parser generator called lemon, which is bundled with the sources. This has to be compiled and run on the build machine, and cannot be cross compiled. Try setting BUILD_CC to the host native compiler. Alternatively, use the Makefile.linux-gcc template used by DRH, and change the variables in there. thoughts? rday -- /\ \ /ASCII RIBBON CAMPAIGN - AGAINST HTML MAIL X - AGAINST MS ATTACHMENTS / \
[sqlite] MPTT Implementation on SQLite with triggers
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hello, I was wondering if there's someone who already implemented the Modified Preorder Tree Traversal (MPTT) algoritme in SQLite using triggers for the modifications (insert,update,delete) If so an example is highly appreciated, if not... well then i will try to make it myself :) Thanks in advance. Peter -BEGIN PGP SIGNATURE- Version: GnuPG v1.2.1 (MingW32) iD8DBQFCuqu+9bwznA9lXw0RAofJAJ4haU3v1g3tCv2W7Hl4eq/sqC6LngCdHCop MHlWycAkbClvCtPnJiSi+t8= =Eilc -END PGP SIGNATURE-
Re: [sqlite] operational errors on insert with Python
The error returned is OperationalError: near ., syntax error. Probably because you need to enclose the version strings in single quotes. OperationalError: no such column: finally Use single quotes around values in the SQL. Contents of double quotes are interpreted as field names. Hugh
Re: [sqlite] Sporadic library routine called out of sequencefrom Tcl interface?
DRH == D Richard Hipp [EMAIL PROTECTED] writes: DRH On Wed, 2005-06-22 at 16:37 -0400, Charles Hines wrote: Things seemed to be going rather well at first, but now quite frequently his app is getting the library routine called out of sequence error (at seemingly random times and places), and I have to say that I'm a little perplexed. DRH I'm perplexed too. It isn't too hard to get an DRH SQLITE_MISUSE from the C interface (just call any DRH of the API routines with a bogus sqlite3* handle, DRH for example) but I thought the TCL interface DRH completely insulated you from all of that. I had a feeling that should be the case... DRH I've been looking through the code and trying DRH things and I cannot reproduce the problem. Please DRH let me know if you get any more clues... I will. Thanks, Chuck -- Charles K. Hines [EMAIL PROTECTED] When things don't sound evil enough on their own I like to toss in a BU-WHA-HA-HA-HA. - Catbert (from Dilbert)
Re: [sqlite] Sporadic library routine called out of sequence fromTcl interface?
Dennis == Dennis Cote [EMAIL PROTECTED] writes: Dennis Charles Hines wrote: I've tried using the various PRAGMAs to help debug it (side note: the vdbe ones don't seem to be working for me, even though I compiled with the --enable-debug flag) as well as putting in an sqlite3 trace command that dumps the strings being sent so I can watch how things are progressing, and nothing odd seems to be happening that is shown at that level. Dennis I ran into the same problem with the VDBE tracing. The configure Dennis script doesn't define the correct compiler flags to generate the VDBE Dennis trace. The fix is detailed in this message: Dennis http://www.mail-archive.com/sqlite-users@sqlite.org/msg05936.html Thanks, I'll manually add that on my next go around! Chuck -- Charles K. Hines [EMAIL PROTECTED] When things don't sound evil enough on their own I like to toss in a BU-WHA-HA-HA-HA. - Catbert (from Dilbert)
[sqlite] Unreachable code in pager.c
While cross-compiling sqlite3.2.1, my Blackfin C compiler gives the following warning: .\src\pager.c, line 1342: cc0111: {D} warning: statement is unreachable assert( rc==SQLITE_OK ); The context is: begin code snippet /* This loop terminates either when the readJournalHdr() call returns ** SQLITE_DONE or an IO error occurs. */ while( 1 ){ // CODE OMITTED WITH NO break; /* rc = sqlite3OsSeek(pPager-jfd, JOURNAL_HDR_SZ(pPager)); */ if( rc!=SQLITE_OK ) goto end_playback; /* Copy original pages out of the journal and back into the database file. */ for(i=0; inRec; i++){ rc = pager_playback_one_page(pPager, pPager-jfd, 1); if( rc!=SQLITE_OK ){ if( rc==SQLITE_DONE ){ rc = SQLITE_OK; pPager-journalOff = szJ; break; }else{ goto end_playback; } } } } /* Pages that have been written to the journal but never synced ** where not restored by the loop above. We have to restore those ** pages by reading them back from the original database. */ assert( rc==SQLITE_OK ); pager_reload_cache(pPager); end_playback: end code snippet I think the compiler is right. I am not familiar with the sqlite3 source code, but the break at line 1330 breaks the for() loop at line 1324, NOT the while() loop at line 1281. Is that as it is intended, or is it a potential bug? Best regards, Frank.
[sqlite] Beta Testers wanted for DragonDB Database Manager
We are looking for beta testers for a new database manager product DragonDB - MVB Edition. A brief description is given below. If you are interested in becoming a beta tester, please send the following information to beta @ dragondb.com: 1. Name 2. E-mail address 3. Company 4. Windows version used for running AppForge MobileVB 5. Version of AppForge MobileVB being used 6. Experience level developing data-centric applications with AppForge MobileVB Please use this subject line for your e-mail: DragonDB MVB Beta Test Reply by e-mail to beta @ dragondb.com Thanks, John Oliva Danic Systems, LLC -- What is DragonDB - MVB Edition? DragonDB is an SQL relational database manager supporting the SQLite3 database format. DragonDB - MVB Edition is a fuser library and software development kit for producing AppForge MobileVB applications using the DragonDB database manager. The SDK is comprised of a set of target specific fusers and MobileVB source code which hides the details of the fuser interface from the application programmer. The currently supported target devices include the Microsoft Pocket PC and Smartphone. Together, DragonDB - MVB Edition and AppForge MobileVB form a powerful toolset for building data-centric applications that run on Windows Mobile devices. --
[sqlite] question about BLOB
in the application I'm writting I would make intensive use of BLOB in fact I have a very simple DB tables. However most of them have a BLOB column where I would put application defined data. The data could easily be over 50K (in fact it would be an in memory .tgz archive with user text and (optionally) images) Basically I would read/write only 1 BLOB at a time and good performance for me would mean no visible latency for the user I just wonder if this could be achieved with good performance, I have read that SQLite is no good with big BLOB. Any similar experience? PS: I cannot test, the GUI is not yet ready! PS2: store the tgz files along the db file is no practical solution for me! I try to have an application file which could be shared with friends, not a 'fragile' directory structure.
Re: [sqlite] how to cross-compile sqlite for PPC?
On Thu, 23 Jun 2005, Robert P. J. Day wrote: On Thu, 23 Jun 2005, Christian Smith wrote: On Thu, 23 Jun 2005, Robert P. J. Day wrote: um ... what appears to be the problem here? certainly, i have the entire gnu development suite installed, and i've used this incantation to cross-compile other packages, like expat. SQLite requires a parser generator called lemon, which is bundled with the sources. This has to be compiled and run on the build machine, and cannot be cross compiled. Try setting BUILD_CC to the host native compiler. as in, just add BUILD_CC=/usr/bin/gcc? same error. or did i misunderstand what you were suggesting? Well, I got it wrong anyway. TARGET_CC is the cross compiler. Have a read of configure.ac, which lists the expected environment variables that can be used. Upon further examination, you need to prefix config_ to the variable name: $ export config_TARGET_CC=cross-gcc $ ./configure ... However, I tried using an arbitrary cross compiler (gcc-h8300-hms) and libtool crapped out anyway. Alternatively, use the Makefile.linux-gcc template used by DRH, and change the variables in there. ok, i'll give that a shot, too, but i'd still like to know what the problem is with the configure phase. One of the known problems is that the autoconf part is basically unmaintained, and noone has stepped up to take the reigns. I always use either the Makefile.linux-gcc as a template, or use my own imake based Imakefile. I'd suggest the former unless you're integrating with another build system and particularly require an autoconf or imake based build. rday Christian -- /\ \ /ASCII RIBBON CAMPAIGN - AGAINST HTML MAIL X - AGAINST MS ATTACHMENTS / \
Re: [sqlite] Unreachable code in pager.c
I counted the parens, and you're right. It's definitely not reachable. I think the compiler is right. I am not familiar with the sqlite3 source code, but the break at line 1330 breaks the for() loop at line 1324, NOT the while() loop at line 1281. Is that as it is intended, or is it a potential bug?
Re: [sqlite] how to cross-compile sqlite for PPC?
On Thu, 23 Jun 2005, Christian Smith wrote: One of the known problems is that the autoconf part is basically unmaintained, and noone has stepped up to take the reigns. i'm starting to see that. to test a local install, i ran the configure with --prefix=/home/rpjday/root and yet, after a susccessful make, when i ran make install it tried to install under /usr. grr. can it really be *that* broken? i'll just use the Makefile-linux.gcc as a starting point for now and see what happens. rday
[sqlite] a couple notes on cross-compiling sqlite3 for the PPC
apparently, it looks like the easiest way to cross-compile sqlite3 for my PPC board will be to just hack the gcc-oriented Makefile. as it stands, that Makefile has a couple critical omissions for me. first, it doesn't support building shared libs, which i'd prefer. also, it's not clear how to disable tcl support just from that makefile, which i'm assuming should be allowable since it was an option with the configure program. in any event, the simplest solution appears to be to just hack up a modified makefile to do what i want. thanks for the info thus far, i'm sure this isn't the end of it. rday p.s. as a side note, the whole point of this exercise is to build a *really* small footprint DB for an embedded system for which space is at a premium, and sqlite came highly recommended. if anyone has a suggestion as to some other, freely-available, OSS DB package that would be worth examining, i'm all ears. i'd like to be able to say i at least considered some alternatives. p.p.s. if tcl support doesn't add a whole lot to the eventual size of the library, then i won't worry overly about disabling it.
Re: [sqlite] a couple notes on cross-compiling sqlite3 for the PPC
On 6/23/05, Robert P. J. Day [EMAIL PROTECTED] wrote: p.s. as a side note, the whole point of this exercise is to build a *really* small footprint DB for an embedded system for which space is at a premium, and sqlite came highly recommended. if anyone has a suggestion as to some other, freely-available, OSS DB package that would be worth examining, i'm all ears. i'd like to be able to say i at least considered some alternatives. It worked well for me too. If you don't need very sophisticated query capability, like you get with sqlite, homebrewed is simple, and dbm is old but workable (it's from early unix).
Re: [sqlite] a couple notes on cross-compiling sqlite3 for the PPC
On Thu, 2005-06-23 at 13:47 -0400, Robert P. J. Day wrote: in any event, the simplest solution appears to be to just hack up a modified makefile to do what i want. thanks for the info thus far, i'm sure this isn't the end of it. I hack the Makefile template for all my builds. I never use autoconf. If you want to use autoconf, you can do this: make target_source That creates subdirectory tsrc that contains all of the generated source code files. Cd into that directory and delete the ones you do not want. (ex: tclsqlite.c and shell.c) then do crosscompiler -o libsqlite.a *.c -- D. Richard Hipp [EMAIL PROTECTED]
Re: [sqlite] a couple notes on cross-compiling sqlite3 for the PPC
p.s. as a side note, the whole point of this exercise is to build a *really* small footprint DB for an embedded system for which space is at a premium, and sqlite came highly recommended. If you look on SourceForge, there is a project called adodotnetsqlite, http://sourceforge.net/projects/adodotnetsqlite/, and the programmers there have mentioned a version of SQLite compiled for handheld platforms. I know that they use a version of that for the .NET provider they are writing.
Re: [sqlite] Update/Join Howto?
On Thu, 2005-06-23 at 14:48 -0400, Mitchell Vincent wrote: UPDATE customer_detail SET customer_id = (SELECT customer_id FROM customers WHERE customers.customer_name = customer_detail.customer_name); This should work. Are you having problems? You'll need version 3.1.0 or later. -- D. Richard Hipp [EMAIL PROTECTED]
Re: [sqlite] Update/Join Howto?
D. Richard Hipp wrote: On Thu, 2005-06-23 at 14:48 -0400, Mitchell Vincent wrote: UPDATE customer_detail SET customer_id = (SELECT customer_id FROM customers WHERE customers.customer_name = customer_detail.customer_name); This should work. Are you having problems? You'll need version 3.1.0 or later. Shoot! I meant to say that I need it to work with 2.8.16 (which was the entire issue!).. *crosses fingers* any way to make that happen? Thanks! -- - Mitchell Vincent - kBilling - Invoices Made Easy! - http://www.k-billing.com
Re: [sqlite] a couple notes on cross-compiling sqlite3 for the PPC
On Thu, 23 Jun 2005, Brass Tilde wrote: p.s. as a side note, the whole point of this exercise is to build a *really* small footprint DB for an embedded system for which space is at a premium, and sqlite came highly recommended. If you look on SourceForge, there is a project called adodotnetsqlite, http://sourceforge.net/projects/adodotnetsqlite/, and the programmers there have mentioned a version of SQLite compiled for handheld platforms. I know that they use a version of that for the .NET provider they are writing. ok, i just took a quick look there and, personally, there's just a wee bit too much .vcl and .vcp and .net and so forth for my comfort level. :-P i'll take a shot at the full sqlite and see where that takes me, but i'll keep the alternative in mind. thanks. rday
Re: [sqlite] Update/Join Howto?
On Thu, 2005-06-23 at 15:32 -0400, Mitchell Vincent wrote: Shoot! I meant to say that I need it to work with 2.8.16 (which was the entire issue!).. *crosses fingers* any way to make that happen? Not really. Version 2 is in maintenance - meaning bugfixes only. All new features go into version 3. -- D. Richard Hipp [EMAIL PROTECTED]
[sqlite] searching for proper date and time stamps
Hello, I'm using the TCL binding of sqlite3 One of the columns in my table has a date and time stamp, something like this: 07/20/2004 01:35:40 06/20/2005 01:37:01 06/20/2005 12:10:07 06/20/2005 12:17:08 06/20/2005 01:35:00 If I want to get all dates that are later than 06/20/2005 01:00:00 I might try: select c1 from t1 where c1 '06/20/2005 01:35:00' But that also returns All the above including 07/20/2004 01:35:40 because (I suppose) comparison starts from the left and it sees 07 which is than 06. Any ideas or hints in general where I can get the dates that I'm looking for? Thanks The information transmitted is intended only for the person(s)or entity to which it is addressed and may contain confidential and/or legally privileged material. Delivery of this message to any person other than the intended recipient(s) is not intended in any way to waive privilege or confidentiality. Any review, retransmission, dissemination or other use of , or taking of any action in reliance upon, this information by entities other than the intended recipient is prohibited. If you receive this in error, please contact the sender and delete the material from any computer. For Translation: http://www.baxter.com/email_disclaimer
Re: [sqlite] Update/Join Howto?
D. Richard Hipp wrote: On Thu, 2005-06-23 at 15:32 -0400, Mitchell Vincent wrote: Shoot! I meant to say that I need it to work with 2.8.16 (which was the entire issue!).. *crosses fingers* any way to make that happen? Not really. Version 2 is in maintenance - meaning bugfixes only. All new features go into version 3. Well, I meant any way to accomplish what I'd like to do in version 2 (doesn't matter how).. -- - Mitchell Vincent - kBilling - Invoices Made Easy! - http://www.k-billing.com
Re: [sqlite] searching for proper date and time stamps
[EMAIL PROTECTED] wrote: Hello, I'm using the TCL binding of sqlite3 One of the columns in my table has a date and time stamp, something like this: datetimes are sorted as strings, maybe that explains Bert 07/20/2004 01:35:40 06/20/2005 01:37:01 06/20/2005 12:10:07 06/20/2005 12:17:08 06/20/2005 01:35:00 If I want to get all dates that are later than 06/20/2005 01:00:00 I might try: select c1 from t1 where c1 '06/20/2005 01:35:00' But that also returns All the above including 07/20/2004 01:35:40 because (I suppose) comparison starts from the left and it sees 07 which is than 06. Any ideas or hints in general where I can get the dates that I'm looking for? Thanks The information transmitted is intended only for the person(s)or entity to which it is addressed and may contain confidential and/or legally privileged material. Delivery of this message to any person other than the intended recipient(s) is not intended in any way to waive privilege or confidentiality. Any review, retransmission, dissemination or other use of , or taking of any action in reliance upon, this information by entities other than the intended recipient is prohibited. If you receive this in error, please contact the sender and delete the material from any computer. For Translation: http://www.baxter.com/email_disclaimer
[sqlite] Attached databases locking
Question... Two database files, say A B. Open A. Attach B. Write to a table in A. Write to a table in B. During the writes, is the file not being written to locked? Thanks, Tim
Re: [sqlite] a couple notes on cross-compiling sqlite3 for the PPC
[23-06-2005 21:32, Robert P. J. Day escreveu] On Thu, 23 Jun 2005, Brass Tilde wrote: If you look on SourceForge, there is a project called adodotnetsqlite, http://sourceforge.net/projects/adodotnetsqlite/, and the programmers there have mentioned a version of SQLite compiled for handheld platforms. I know that they use a version of that for the .NET provider they are writing. ok, i just took a quick look there and, personally, there's just a wee bit too much .vcl and .vcp and .net and so forth for my comfort level. :-P i'll take a shot at the full sqlite and see where that takes me, but i'll keep the alternative in mind. thanks. The code they use is from http://sqlite-wince.sf.net But I don't know if that helps you as it's a windows API thing. It could give you some ideas on what you need to do the port, and the patch is done so that the same source can be used on other systems (like linux Windows). I think the only advantage is that it's all pre-processed code, so you don't need to run the lemon parser to generate some files, etc. (but you can get the same thing by downloading the pre-processed source from the sqlite site). Regards, ~Nuno Lucas
RE: [sqlite] a couple notes on cross-compiling sqlite3 for the PPC
ok, i just took a quick look there and, personally, there's just a wee bit too much .vcl and .vcp and .net and so forth for my comfort level. :-P i'll take a shot at the full sqlite and see where that takes me, but i'll keep the alternative in mind. thanks. Understood, I was refering to the fact that he was compiling for the platform. I was thinking you might get some pointers from how he does it.
Re: [sqlite] searching for proper date and time stamps
[EMAIL PROTECTED] wrote: Hello, I'm using the TCL binding of sqlite3 One of the columns in my table has a date and time stamp, something like this: 07/20/2004 01:35:40 06/20/2005 01:37:01 06/20/2005 12:10:07 06/20/2005 12:17:08 06/20/2005 01:35:00 If I want to get all dates that are later than 06/20/2005 01:00:00 I might try: select c1 from t1 where c1 '06/20/2005 01:35:00' But that also returns All the above including 07/20/2004 01:35:40 because (I suppose) comparison starts from the left and it sees 07 which is than 06. Any ideas or hints in general where I can get the dates that I'm looking for? Thanks Either store your datetime stamp as /MM/DD HH:MM:SS, eg 2005/06/20 11:23:35 so that the string comparison works on them as expected, or use the Unix time format, e.g number of seconds since Jan 1 1970, which Tcl will happily convert to and from using clock scan and clock format. There are also some fucntions in Sqlite that can deal with this format - see http://www.sqlite.org/cvstrac/wiki?p=DateAndTimeFunctions Lawrence The information transmitted is intended only for the person(s)or entity to which it is addressed and may contain confidential and/or legally privileged material. Delivery of this message to any person other than the intended recipient(s) is not intended in any way to waive privilege or confidentiality. Any review, retransmission, dissemination or other use of , or taking of any action in reliance upon, this information by entities other than the intended recipient is prohibited. If you receive this in error, please contact the sender and delete the material from any computer. For Translation: http://www.baxter.com/email_disclaimer
Re: [sqlite] Attached databases locking
On Thu, 2005-06-23 at 14:50 -0700, Tim McDaniel wrote: Question... Two database files, say A B. Open A. Attach B. Write to a table in A. Write to a table in B. During the writes, is the file not being written to locked? No locks are taken on unused databases. -- D. Richard Hipp [EMAIL PROTECTED]
[sqlite] Database opens OK but further calls result in MISUSE
Hi I'm trying to write a SQLite module for BlitzMax (www.blitzmax.com) and have run in to some difficulty. I've taken the pure C source sqlite-source-3_2_2.zip file and mapped the C functions directly to Max functions (Max produces *.s code and then uses GCC to compile and link those and any required *.c/*.cpp files together). I've started with something fairly simple - opening and closing a database. --- rc = sqlite3_open(test.db, db) If Not rc=SQLITE_OK Print(Can't open database +rc) sqlite3_close(db) End Else Print(Opened: +rc) EndIf Print(Errcode: +sqlite3_errcode(db)) Print(Closing: +sqlite3_close(db)) --- That produces the following: --- Opened: 0 Errcode: 21 Closing: 21 --- So sqlite3_open() is returning sucessfully (the file test.db is created) but a call to any other sqlite function returns 21 (SQLITE_MISUSE). I'm still probing around and the problem's almost certainly with the way Max shares its variables with C code, but from what I can tell of SQLite, this sort of thing shouldn't happen in a single threaded app. Maybe someone can make a more informed guess as to why this is happening? It seems a little strange that this should happen at all - surely sqlite3_open() should return 21 as well if there's a problem? Thanks in advance. James
Re: [sqlite] Update/Join Howto?
Mitchell Vincent wrote: D. Richard Hipp wrote: On Thu, 2005-06-23 at 15:32 -0400, Mitchell Vincent wrote: Shoot! I meant to say that I need it to work with 2.8.16 (which was the entire issue!).. *crosses fingers* any way to make that happen? Not really. Version 2 is in maintenance - meaning bugfixes only. All new features go into version 3. Well, I meant any way to accomplish what I'd like to do in version 2 (doesn't matter how).. Mitchell, You can accomplish the same thing with something like the SQL below. I have abbreviated your field names, but you should get the idea. --use a transaction to ensure it all gets done (or nothing is changed) begin transaction --create a temporary detail table with the same columns as your permanent detail table create temp table t_det(c_name, c_id, c_other); --copy the data into the temp table from either the customer table -- joined by name, or the existing detail table insert into t_det select cd.c_name, coalesce(c.id, cd.c_id), cd.c_other from c_det as cd left join cust as c using(c_name); --delete all the records from the permanent detail table delete from c_det; --copy the temp table back into the permanent table insert into c_det select * from t_det; --delete the temp table drop table t_det; commit transaction HTH Dennis Cote
[sqlite] UNIQUE Constraint but case sensitive
Hi, I need to create a unique constraint on a column of type varchar, but it is not case sensitive by default. Does any one know how to make a unique constraint case sensitive? Thanks and best regards, Ajay Sonawane