I am really posting this out of desperation after searching around a lot for an answer and trying a few different things with no success. I have an Access database where I have recently migrated the tables to SQL 2005, Access continues to function to the users as a front-end providing forms, reports, and queries. However, since moving to the
Tag: database
Best table design for application configuration or application option settings?
I need to store a series of configuration values in a database. A couple ways I thought of to store them are: a table with 2 colums(name,value) and a row for each pair, or a table with a column for each config parameter and 1 row? With the first I only need to add another row to add a config
Can I add a UNIQUE constraint to a PostgreSQL table, after it’s already created?
I have the following table: tickername | tickerbbname | tickertype ————+—————+———— USDZAR | USDZAR Curncy | C EURCZK | EURCZK Curncy | C EURPLN | EURPLN …
How to think in SQL?
How do I stop thinking every query in terms of cursors, procedures and functions and start using SQL as it should be? Do we make the transition to thinking in SQL just by practise or is there any …
Calculating the closest future periodic payment date in SQL
I’m working on an application that deals with periodic payments Payments are done fortnightly i.e. payment 1: 2009-06-01 payment 2: 2009-06-15 payment 3: 2009-06-29 and now I need a SQL statement …
Deferrable Constraints in SQL Server
Do any versions of SQL Server support deferrable constraints (DC)? Since about version 8.0, Oracle has supported deferrable constraints – constraints that are only evaluated when you commit a …
What is the difference between JOIN and UNION?
What is the difference between JOIN and UNION? Can I have an example?
What’s the fastest way to do a bulk insert into Postgres?
I need to programmatically insert tens of millions of records into a Postgres database. Presently, I’m executing thousands of insert statements in a single query. Is there a better way to do this, some bulk insert statement I do not know about? Answer PostgreSQL has a guide on how to best populate a database initially, and they suggest using the
How can I do a BEFORE UPDATED trigger with sql server?
I’m using Sqlserver express and I can’t do before updated trigger. There’s a other way to do that? Answer MSSQL does not support BEFORE triggers. The closest you have is INSTEAD OF triggers but their behavior is different to that of BEFORE triggers in MySQL. You can learn more about them here, and note that INSTEAD OF triggers “Specifies that
Drop all tables command
What is the command to drop all tables in SQLite? Similarly I’d like to drop all indexes. Answer