Readdy Write

Änderungen von SqlServer zu SQLite

04.07.2018 (👁3110)

Wechsel in SQL Datenbank Server

Das alles müsst ihr ändern, wenn ihr von SQLserver auf SQLite wechselt

1)  TOP 1 -> LIMIT 1

SELECT TOP 1 Fields       wird    WHERE Contition LIMIT 1

 

2) NOT NULL

NOT [Field] IS NULL   wird zu   [FIELD] IS NOT NULL

 

3) DataTable ->DataReader

DataTable wird zu DataReader

4) EOF->HasRows

 .EOF ==true wird zu .HasRows==false

5) SYSDATETIME() wird CURRENT_TIMESTAMP

 [dtScan] = CURRENT_TIMESTAMP"//SYSDATETIME()

string sSQL = "SELECT [IDProject_On_Server] FROM tbl_Details WHERE [dtDeleted] IS NOT NULL";

            SqliteDataReader dataReader = clsDB.Get_DataReader(sSQL);

            if (dataReader.HasRows == true)

            {

                while(dataReader.Read())

                {

                    //---< NoMatch: Delete on Server >---

                    string IDProject_on_Server = dataReader["IDProject_on_Server"].ToString();

                    fx_Log("delete byWebsite" + IDProject_on_Server);

                    //</ nomatch >

DataReader

SqliteDataReader dataReader = clsDB.Get_DataReader(sSQL);

 

 

Wird mit

SqliteDataReader dataReader = clsDB.Get_DataReader(sSQL);

 

 


0,00 €