Skip to content

Commit

Permalink
Add support for temporary tables
Browse files Browse the repository at this point in the history
  • Loading branch information
hazzik committed Jun 5, 2024
1 parent 2f715c2 commit b989fb4
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
2 changes: 2 additions & 0 deletions .github/workflows/NetCoreTests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,10 @@ jobs:
DB_INIT: |
docker run --name DB2 --privileged=true -e DB2INSTANCE=nhib -e DB2INST1_PASSWORD=nhib -e DBNAME=nhib -e LICENSE=accept -e AUTOCONFIG=false -e ARCHIVE_LOGS=false -p 50000:50000 -d icr.io/db2_community/db2:11.5.9.0
docker logs -f DB2 | sed '/(*) Setup has completed./ q'
docker exec DB2 su - nhib bash -c "db2 connect to nhib; db2 CREATE USER TEMPORARY TABLESPACE TEMPSPACE_32"
DB2_CLI_DRIVER_INSTALL_PATH="$(pwd)/src/NHibernate.Test/bin/Release/net8.0/clidriver"
echo "DB2LANG=en_US" >> $GITHUB_ENV
echo "DB2_CLI_DRIVER_INSTALL_PATH=$DB2_CLI_DRIVER_INSTALL_PATH" >> $GITHUB_ENV
echo "LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$DB2_CLI_DRIVER_INSTALL_PATH/lib" >> $GITHUB_ENV
echo "LIBPATH=$LIBPATH:$DB2_CLI_DRIVER_INSTALL_PATH/lib" >> $GITHUB_ENV
Expand Down
3 changes: 3 additions & 0 deletions src/NHibernate/Dialect/DB2Dialect.cs
Original file line number Diff line number Diff line change
Expand Up @@ -1132,5 +1132,8 @@ public override string ForUpdateString
public override bool DoesReadCommittedCauseWritersToBlockReaders => true;

#endregion

public override bool SupportsTemporaryTables => true;
public override string CreateTemporaryTableString => "create global temporary table";
}
}

0 comments on commit b989fb4

Please sign in to comment.