I wanted to build an awesome place for people to discuss module specific issues, but I don't have any more time for this, and there are much better places to discuss Perl-related issues. I'd recommend asking your question on Stack Overflow or on Perl Monks.
If you are looking for a Perl tutorial or Perl-related news, I hope these links will serve you well.
Posted on 2006-12-28 00:53:58-08 by jcasadonte in response to 3913
Re: full_column_names pragma problem

One of the nice folks on the SQLite mailing list pointed this out to me. It seems like it is the cause of the problems....

See "drop table name from field name" below...

SV * sqlite_st_FETCH_attrib (SV *sth, imp_sth_t *imp_sth, SV *keysv) { char *key = SvPV_nolen(keysv); SV *retsv = NULL; int i,n; if (!DBIc_ACTIVE(imp_sth)) { return NULL; } /* warn("fetch: %s\n", key); */ i = DBIc_NUM_FIELDS(imp_sth); if (strEQ(key, "NAME")) { AV *av = newAV(); /* warn("Fetch NAME fields: %d\n", i); */ av_extend(av, i); retsv = sv_2mortal(newRV(sv_2mortal((SV*)av))); for (n = 0; n < i; n++) { /* warn("Fetch col name %d\n", n); */ const char *fieldname = sqlite3_column_name(imp_sth->stmt, n); if (fieldname) { /* warn("Name [%d]: %s\n", n, fieldname); */ char *dot = instr(fieldname, "."); if (dot) /* drop table name from field name */ fieldname = ++dot;

The correct behavior would, I think, be to pass along whatever SQLite passes back, and let end-user control it via the aforementioned pragmas. More information on the pragmas can be had at:

http://www.sqlite.org/pragma.html

joe
Direct Responses: Write a response