Namespaces

  • Latte
    • Loaders
    • Macros
    • Runtime
  • Nette
    • Application
      • Responses
      • Routers
      • UI
    • Bridges
      • ApplicationDI
      • ApplicationLatte
      • ApplicationTracy
      • CacheDI
      • CacheLatte
      • DatabaseDI
      • DatabaseTracy
      • DITracy
      • FormsDI
      • FormsLatte
      • Framework
      • HttpDI
      • HttpTracy
      • MailDI
      • ReflectionDI
      • SecurityDI
      • SecurityTracy
    • Caching
      • Storages
    • ComponentModel
    • Database
      • Conventions
      • Drivers
      • Reflection
      • Table
    • DI
      • Config
        • Adapters
      • Extensions
    • Forms
      • Controls
      • Rendering
    • Http
    • Iterators
    • Loaders
    • Localization
    • Mail
    • Neon
    • PhpGenerator
    • Reflection
    • Security
    • Utils
  • none
  • Tracy
    • Bridges
      • Nette

Classes

  • Connection
  • Context
  • Helpers
  • ResultSet
  • Row
  • SqlLiteral
  • SqlPreprocessor
  • Structure

Interfaces

  • IConventions
  • IReflection
  • IRow
  • IRowContainer
  • IStructure
  • ISupplementalDriver

Exceptions

  • ConnectionException
  • ConstraintViolationException
  • DriverException
  • ForeignKeyConstraintViolationException
  • NotNullConstraintViolationException
  • UniqueConstraintViolationException
  • Overview
  • Namespace
  • Class
  • Tree
  • Deprecated
  • Other releases
  • Nette homepage

Class Helpers

Database helpers.

Namespace: Nette\Database
Located at Database/Helpers.php
Methods summary
public static
# dumpResult( Nette\Database\ResultSet $result )

Displays complete result set as HTML table for debug purposes.

Displays complete result set as HTML table for debug purposes.

public static string
# dumpSql( string $sql, array $params = NULL, Nette\Database\Connection $connection = NULL )

Returns syntax highlighted SQL command.

Returns syntax highlighted SQL command.

Parameters

$sql
$params
$connection

Returns

string
string
public static array
# detectTypes( PDOStatement $statement )

Common column type detection.

Common column type detection.

Returns

array
array
public static integer
# loadFromFile( Nette\Database\Connection $connection, $file )

Import SQL dump from file - extremely fast.

Import SQL dump from file - extremely fast.

Returns

integer
count of commands
public static
# createDebugPanel( $connection, $explain = TRUE, $name = NULL )
public static array
# toPairs( array $rows, $key = NULL, $value = NULL )

Reformat source to key -> value pairs.

Reformat source to key -> value pairs.

Returns

array
array
Properties summary
public static integer $maxLength

maximum SQL length

maximum SQL length

#100
public static array $typePatterns
#array( '^_' => IStructure::FIELD_TEXT, // PostgreSQL arrays 'BYTEA|BLOB|BIN' => IStructure::FIELD_BINARY, 'TEXT|CHAR|POINT|INTERVAL' => IStructure::FIELD_TEXT, 'YEAR|BYTE|COUNTER|SERIAL|INT|LONG|SHORT|^TINY$' => IStructure::FIELD_INTEGER, 'CURRENCY|REAL|MONEY|FLOAT|DOUBLE|DECIMAL|NUMERIC|NUMBER' => IStructure::FIELD_FLOAT, '^TIME$' => IStructure::FIELD_TIME, 'TIME' => IStructure::FIELD_DATETIME, // DATETIME, TIMESTAMP 'DATE(?!RANGE)' => IStructure::FIELD_DATE, 'BOOL' => IStructure::FIELD_BOOL, )
Nette 2.3-20161221 API API documentation generated by ApiGen 2.8.0