Tip Bank

DevX - Software Development Resource

SQL and Using Text and Combo Boxes

Question: I write a statement such as frmStatistics.datStatistics.RecordSource = “SELECT * FROM tblSpecialGroup Where Sex = ‘M’ AND Date BETWEEN ‘” & “051099” & “‘” & ” And ” &

DevX - Software Development Resource

Migration from FOCUS 6.0 to SQL Server 7.0

Question: Are there any tools coming with SQL Server 7.0 for this migration from FOCUS 6.0? If not, what is the best way to accomplish this migration? Answer: Yes, DTS

DevX - Software Development Resource

Business Rules and Semantic Object Models

Question: What are business rules in relation to a DBMS. Do you have any posssible examples for a university database? Also: Do you have any hints to drawing a Semantic

DevX - Software Development Resource

Replication: Many Clients, One Central DB

Question: Being new to SQL Server 7.0 I wanted to get other opinions on this: My company has many clients using a proprietary db schema that will replicate transactions to

DevX - Software Development Resource

Power2 – A power of 2

‘ Raise 2 to a power’ the exponent must be in the range [0,31]Function Power2(ByVal exponent As Long) As Long Static res(0 To 31) As Long Dim i As Long

DevX - Software Development Resource

BitSet – Set a bit in a number

‘ Set a bit in a value” NOTE: requires Power2()Function BitSet(ByVal value As Long, ByVal bit As Long) As Long ‘ simply OR with the bit mask ‘ Range checking

DevX - Software Development Resource

BitTest – Test the value of a bit

‘ Test the value of a bit” NOTE: requires Power2()Function BitTest(ByVal value As Long, ByVal bit As Long) As Boolean ‘ simply AND with the bit mask ‘ Range checking

DevX - Software Development Resource

BitClear – Clear a bit in a value

‘ Clear a bit in a value” NOTE: requires Power2()Function BitClear(ByVal value As Long, ByVal bit As Long) As Long ‘ simply AND with the negation of the bit mask

DevX - Software Development Resource

ShiftLeft – Shift a Long to the left

‘ Shift to the left of the specified number of times” NOTE: requires Power2()Function ShiftLeft(ByVal value As Long, ByVal times As Long) As Long ‘ we need to create a