Re: [sqlite] Use of strftime in a CREATE INDEX sintax.

2010-06-25 Thread Jay A. Kreibich
On Fri, Jun 25, 2010 at 11:16:58AM -0400, Igor Tandetnik scratched on the wall: > Danilo Cicerone wrote: > > I'm trying to create an index as follow: > > > > CREATE UNIQUE INDEX Numerazione ON FattureCli (fat_numfat, strftime('%Y', > > fat_datfat)) ON CONFLICT FAIL; > > > > Could it be translated

Re: [sqlite] Use of strftime in a CREATE INDEX sintax.

2010-06-25 Thread Igor Tandetnik
Danilo Cicerone wrote: > I'm trying to create an index as follow: > > CREATE UNIQUE INDEX Numerazione ON FattureCli (fat_numfat, strftime('%Y', > fat_datfat)) ON CONFLICT FAIL; > > Could it be translated into a corret sintax without add another field > (fat_year)? No. -- Igor Tandetnik ___

[sqlite] Use of strftime in a CREATE INDEX sintax.

2010-06-25 Thread Danilo Cicerone
Hi to all, I'm trying to create an index as follow: CREATE TABLE FattureCli ( fat_id INTEGER PRIMARY KEY, fat_rif_sogid INTEGER DEFAULT NULL, fat_rif_mpaid INTEGER DEFAULT NULL, fat_numfat INTEGER NOT NULL, -- It would be unique by year; fat_datfat CHAR(10) NOT NULL, -- -MM-DD;