Giter VIP home page Giter VIP logo

dbsystem's Introduction

Languages

العربية - English

Document

Features

  • SELECT DATA
  • INSERT DATA
  • File Config define - config/app.php
  • how to make Config app and database
  • functions Query()
  • BluePrint Queries
    • INT
    • TEXT
    • VARCHAR
    • BigIneger
    • Timestamps [created_at & updated_at]

How to Setup

  • Install Library composer require i74ifa/dbsystem

how to Use

  • you need Session because the error storage on $_SESSION['errors']

      session_start();
      require "vendor/autoload.php";
      use DBsystem74I\Database\DB;
    
      $DB = new DB;
    
  • You have var $DB

SELECT DATA

  $result = $DB->table('nametable')->Select(['*'])->run();

  foreach ($result as $row) {
    echo $row['nameCol1'] . '<br>';
    echo $row['nameCol2'] . '<br>';
  }

Insert Data

  • you have two method to insert INSERT() & INSERTCol()

  • INSERT()

    • this function to insert all Columns

      • you don't need type name Column

          //Data in Table users
          |---------------------------------|
          | id | name | username | password |
        
      • INSERT to All Columns :

        $DB->table('users')->INSERT([1, 'anyName', 'username', 'Password'])->run();
        
  • INSERTCol()

    • Use this Method if you don't need insert Columns NULL or id is AUTO_INCREMENT()

       $DB->table('users')->INSERTCol(['name', 'username'], ['value name', 'value username'])->run();
      

Migration Data Table

  • This Option is Beta I use it
  • Go in vendor/i74ifa/dbsystem/Migration/Migrate.php

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.